using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;

public class MapCanvas : MonoBehaviour
{
    public Dropdown _dropdown;
    // Start is called before the first frame update
    void Start()
    {
        _dropdown.onValueChanged.AddListener(OnValueChange);
    }

    private void OnValueChange(int arg0)
    {
        if (arg0 == 0)
        {
            map.Instance.EvaluationFunctionType = EvaluationFunctionType.Manhattan;
        }
        
        if (arg0 == 1)
        {
            map.Instance.EvaluationFunctionType = EvaluationFunctionType.Diagonal;
        }
        
        if (arg0 == 2)
        {
            map.Instance.EvaluationFunctionType = EvaluationFunctionType.Euclid;
        }
    }

    // Update is called once per frame
    void Update()
    {
        
    }
}
